Matrix multiplier for obtaining the dot product of two vectors

ABSTRACT

A MATRIX MULTIPLIER FOR USE IN LEARNING MACHINES IN WHICH THE DOOT PRODUCT OF TWO VECTORS MAY BE READILY OBTAINED AND WHERE AT LEAST ONE VECTOR MAY CONTAIN NUMEROUS COMPONENTS. THE APPARATUS OF THE INVENTION COMPRISES A   CATHODE-RAY TUBE, A SHEET OF PHOTOCHROMIC FILM DISPOSED OVER THE FACE OF THE FILM OPPOSITE THE TUBE AND FACING THE TUBE FACE.

United States Patent Inventor ChariesA. Roeen Atherton, Cali.

Appl. No. 580,083

Filed Sept. 16, 1966 Patented June 28, 1971 Assignee Stanford Resarch Institute Menlo Park. Calif.

MATRIX MULTIPLIER FOR OBTAINING THE DOT (inquired),l72.85;235/181,164,l65,171,156. 198, 186 I89, I93 I94; 250/20I;205, 206;

[56] References Cited UNITED STATES PATENTS 2,994,779 8/1961 Brouillette, Jr 235/198X 3,265,870 8/1966 Bose 235/198X 3,418,459 12/1968 Purdy et al 235/198X 3.423.528 1/1969 Bradshaw et a1 235/198X Primary Examiner-Eugene G. Botz Assistant Examiner-Joseph F. Ruggiero Attorneys-James Todorovic and Samuel Lindenberg ABSTRACT: A matrix multiplier for use in learning machines in which the dot product of two vectors may be readily obtained and where at least one vector may contain numerous components. The apparatus of the invention comprises a cathode-ray tube, a sheet of photochromic film disposed over the face of the tube, and several photoceils disposed on the 3 I5/( inquired) side of the film opposite the tube and facing the tube face.

X O X 0 w 0 o w 0 42 l Fl 56 4 5o ADD X 0 X O UU O $4 LU O 46 z(xw xlul xrw x 1 DIFFERENCE CIRCUIT I l I r 52 54 Z( w+xw) ADD xw' by-t-cz and MATRIX MULTIPLIIR FOR OBTAINING THE DOT PRODUCT OI TWO VECTORS This invention relates to learning machines, and more particularly to apparatus and methods for obtaining certain mathematical relationships of quantities for use in connection with each machine.

Learning machines are employed to recognize certain characters or representations when they are exhibited in any form within a wide range. Such machines often must perform complex mathematical manipulations. One of such manipulatlons involves the obtaining of the dot product of vectors, each having numerous components. The obtaining of the dot product of two vectors generally involves the obtaining of the products of the corresponding components and adding them. For example, if vectors and have components in three mutually ndicular directions X, Y and Z. w re Til-x4- then the dot product]:- is given by ga i bc-l qfiwhile dot products can be readily obtained where each vector has a limited number of components, such as the three in the foregoing example, the complexity of the required equipment normally increases enormously as the number of components increases. Thus, where at least one of the vectors has thousands of components, as may occur in learning machines of high capacity, a means for obtaining dot products in a simple manner would be of great utility.

Accordingly, one object of the present invention is to provide apparatus for performing complex mathematical calculations, which is simpler and more economical than apparatus available heretofore.

Another object is to provide apparatus for readily obtaining the dot product of two vectors, where at least one vector may contain numerous components.

The foregoing and other objects are realized in one embodiment of the invention by apparatus comprising a cathode-ray tube (CRT), a sheet of photochromic film disposed over the entire face of the tube, and several photocells disposed on the side of the film opposite the tube, and facing the tube face. Photochromic film has the property of acting as a blocking means by becoming opaque when light is caused to shine on it, the opacity of any spot on the film increasing with amount of exposure to light. To obtain the dot product involving a vector W which may have perhaps [0,000 components, the flying spot scanner of the CRT covers a square of l00 l00 line resolution, thus providing l0,000 individual areas. Each of these areas is illuminated with a brightness proportional to the magnitude of the W component it represents, by varying the CRT cathode-anode voltage. The photochromic film registers the W components by reason of each area of the film in the 100x100 line square attaining an opacity proportional to its corresponding W component.

To obtain the dot product light is caused to shine through the photochromic film to a photocell behind it. The light may be obtained by the flying spot scanner impinging on the CRT phosphors, but with an intensity so low that the opacity of the photochromic film is not appreciably affected. Each X component of shines on the same area of the film on which its corresponding W component is registered. Thus, the amount of light shining through each of the 10,000 areas is proportional to a W component which affected the opacity of the film at that area. and the X component, which is represented by the intensity of light shining in the area. The light reaching the photocell behind the film is equal to the productXW for corresponding X's and W's, and the total illumination on the entire photocell is equal to the sum (gall of these products XW. That sum is the dot product The storage time of the photocell and/or the phosphor of the illuminating CRT is long enough and the X components are displayed rapidly enough that the fact that a finite time is required to cover all l0,000 areas has no effect on the photocell output; therefore the output of the photocell is proportional to the sum of all XW components, as though they were present simultaneously.

The CRT face is generally large enough to enable several dot products to be taken; Thus, for a tube with 500 by 500 line resolution, 25 square yielding ZS-dot products can be obtained, where each square has by I00 line resolution and therefore can accommodate vectors of 10,000 components.

In order to provide for cases where one of the vectors has negative components, two identical CRT-film-photocell combinations are used, with one registering only positive products and one only negative products. The outputs of corresponding photocells are delivered to a difference amplifier which subtracts the negative registering photocell output from the one representing positive products. In cases where each vector has negative components four CRT-film-photocell combinations can be used. Instead of using separate CRT's, different areas of the same CRT tube face may be used where negative components exist.

The foregoing and other features and a more complete understanding of the invention may be had by reference to the following description and claims, talten in conjunction with the accompanying drawings wherein:

FIG. 1 is a simplified side view of one embodiment of the invention;

FIG. 2 is a representation of the face of a cathode-ray tube used for deriving 25 dot products;

FIG. 3 is an enlarged representation of a portion of H6. 2; and

FIG. 4 is a representation of four CRT-film-photocell combinations for obtaining dot products of two vectors where either one may have negative components.

FIG. I illustrates one embodiment of the invention comprising a cathode-ray tube (CRT) 10 having a cathode 18 and anode 20 and focusing apparatus 17. The face [2 of the CRT carries phosphor which emits light when hit by the CRT electron beam 2l. A sheet of photochromic film i4 is disposed in facewise contract with the face of the tube l0, and a group of 25 cadmium sulfide photocells I6 is positioned against the film on the side thereof opposite the tube face.

Photochromic film has the property of becoming opaque when subjected to optical radiation, the opacity of any spot on the film increasing with the amount of light incident thereon. The film also has the property that a decrease in opacity occure with rise in temperature. this latter property being useful in renovating an exposed sheet of film to enable its reuse. Photochromic film currently available is highly susceptible to opacity increase when subjected to light in the region of 3500 to 4000 A. and can be bleached (opacity removed) by the heat resulting from irradiation with light having a wavelength of 5000 to 10,000 A. Such photochromic film is manufactured by the Eastman Kodak Company for example and also by the National Cash Register Company.

FIG. 2 represents the face [2 of the CRT 10 of H6. 1. The apparatus illustrated in the F165. is used to obtain up to 25 dot products, and each square, such as those labeled Area 1" and "Area 2, represents one area of the tube and of the film l4, and one of the alphotocells 16, each area being employed to obtain one dot product. The CRT face is scanned with 500 horizontal and $00 vertical lines, so each of the 25 areas has a 100 by I00 line matrix, and can represent l0,000 components. FIG. 3 illustrates part of the area of the photochromic film in detail, and illustrates how each of the 25 areas, such as Area I, can represent up to l0,000 components. Each of the area bits, which are labeled W through W may have applied thereto a different intensity of illumination, which corresponds to a different valu of the component.

The dot product of two vectors and are obtained by first registering the W vector on the photochromic film. This is accomplished by generating an electron beam, which moves from the cathode 18, past the anode 20 and impinges on a very small area of the tube face, causing the phosphors 12 at that area to glow and emit light. This light causes a small area of the photochromic film 14 to become somewhat opaque, the degree of opacity being proportional to the amount of light hitting the area. in other words, the opacity is equal to the integral of the intensity of light times its duration. Deflection plates or coils 19 move the beam vertically and horizontally in a predetermined psttem. For the case where only one dot product is to be obtained and only one of the 25 areas is to be used, the beam traverses Area I in horizontal bands. The beam starts at the area bit W,. and moves horizontally to area bit W.,.. and is "blanked" or turned off as it moves to area bit W The beam then traverses from W to W,.,, from W,.,,, to V1,... and so forth until it moves from W to W As the electron beam moves from W. to W... of Area i. the cathode to anode voltage is varied in accordance with the magnitudes of the W component represented at each area bit. Thus. if component W. has a high magnitude. the cathodeanode voltage is adjusted to a value which makes the photochromic film highly transparent in the W area bit. if the w vector contains less than i0,000 components. then all area bits not used are made highly opaque by using maximum electron beam intensity (highest cathode-anode voltage) as the beam moves over the unused area bits.

When the electron beam has traversed all area bits of Area 1, the portion of the photochromic i'tlm covering Area I has been transformed into a mask. This mask has a transparency at each area bit, proportional to the magnitude of the W com ponent represented by that area bit.

The next step in obtaining the dot productX-W is to scan the same Area I by the electron beam, whose intensity at each area is not controlled by the value of the X component. The light resulting from the electron beam striking the phosphor at 12, passes through the photochromic film i4 and impinges on that photocell 16 covering Area I. The intensity of the electron beam at each area bit is now made proportional to the magnitude of the X component corresponding to that area bit, and therefore the amount of light which shines on each area bit of the photochromic film is proportional to the X component. Since the transparency of the photochromic film was made proportional to the corresponding W component. and the amount of light now striking the film is proportional to the X component, the amount of light which passes through the film and impinges on the photocell 16 is proportional to XW for corresponding X's and Ws, at each area bit. In order to prevent the light from the second scanning from making the photochromic film ue, light of low intensity. as compared to that used for the waning is used.

The light striking the photocell at each area bit causes cur rent to flow through the photocell. A battery (not shown) is connected to the photocell to provide the current. The photocell 16 has a slow reaction time. whereby light striking an area thereof reduces the resistance of the cell (to allow an increased current flow) for an appreciable length of time. for example one-tenth second. The electron beam representing the vector X traverses the entire Area 1 in a small fraction of a second. such as one-thousandth of a second. Thus, the contribution of each area bit toward increasing current flow through the photocell add as though all area bits were illuminated simultaneously. Instead of relying on a slow reaction time of the photocell, a CRT can be employed wherein the phosphors glow for an appreciable time which is longer than the time required for the electron beam to traverse the Area I. The output of the photocell l6 covering Area I is thus equal (actually proportional) to the sum of the products XW for all corresponding components of the vectorsX and w. which is equal to the dot product of the two vectors.

The apparatus illustrated in the FIGS. is designed to obtain up to 25 separate dot products. This is accomplished by performing the same two-time scanning for each of the other 24 areas. using in each area the and vectors where dot products are required. in many applications involving leamlng machines, the same Y vector is used in all IS-dot products. and only the W vector varies. in those cases single amplitude light source with the light proportional to is caused to illuminate the grin photoehromic film after it has been converted to a mask. The output will then be X-W, X'W, X-Wn.

The learning machine applies ns often involve dot products where one of the vectors of each dot product has components all of the same magnitude. in that case a single light source. such as an incandescent lamp. directed onto one of the 25 areas, can be employed instead of using an electron beam scanning. Of course. the division into 25 areas and the use of I00 by I00 line areas is given merely to present a concrete example to aid in the understanding of the invention, rather than as a preferred embodiment thereof.

In some applications for which dot products are required, at least one of the vectors has negative components. The product of a negative component from one vector and a positive corresponding component of another vector is negative. and this quantity should be subtracted from the sum of all positive products. One method for enabling the required subtraction is by providing two synchronously running CRT's. each having a sheet of photochromic film and a group of photocells. The two CRTJ'tlm-cell combinations can be used where the vector has negative components, by registering only positive W components on the first CRT and only negative W components on the second CRT. The outputs of corresponding photocells. one from each CRT and covering corresponding areas. are delivered to a difference amplifier which yields their difference. This difference is the product of the vectors. Apparatus for obtaining dot products where each of the vectors may have negative components is shown in FIG. 4.

The apparatus of FIG. 4 comprises four devices 40. 42, 44 and 46, each including a cathode-ray tube, a sheet of photochromic l'tlm covering the face, and 25 cadmium-sulfide photocells facing the film. similar to that shown in FIG. 1. The apparatus is useful for obtaining the dot product of up to 25 sets of vectors and where either vector may have negative comgnents. Each CRT device is the same except that positive components are delivered to the cathodes (or anodes, depending on which element varies in voltage) of only devices 40 and 44 while negative components are delivered to the cathodes of only devices 42 and 46. Similarly. positive i coi nponents go only to CRT devices 40 and 46 while negative components go only to devices 42 and 44. Diodes may be used to direct currents of the appropriate polarity to the CRT devices.

The outputs of the photocells of devices 40 and 42 are the same polarity of the XW products where both components X and W are positive or both are negative; both fthese same represent the positive parts of the dot products The outputs of the photocells of devices 44 and 46 are the sums of the XW products where only one of the components X or W is positive and the other is negative; both of these sums represent the negative parts of the dot productY- By adding the positive sums together and subtracting the negative sums. for each of the 25 areas. one obtains the true dot product for the vectors displayed on that area.

By way of illustration of the foregoing FIG. 4 is a schematic arrangement for use in connection with one area of the devices 40. 42, 44, 46. say Area 24. The outputs of the two photocells 48 and 50, and two photocells 52 and 54 covering the designated Area 24 of each of the devices are respectively combined in adders 56 and 58. The output of the adders are applied to a d rence amplifier 60, the output of which is the dot roductX In the F IG. the prime notation. such as X' or W. indicates that a negative quantity is being dealt with. The outputs of devices 40 and 42 are positive. and their sum is obtained from adder 56. The output of devices 44 and 46 are negative. and their sum is obtained from adder 58. The difference between the positive quantities are obtained from difference amplifier 60. and the output of this circuit is the required dot product. Similar circuitry is employed for each of the other 24 areas.

While negative products can be dealt with by providing four separate CRT-fllm-photocell devices. a simpler wsy is to employ four separate areas of the same device. While the capacity of s IS-area CRT device would be reduced to obtaining 6- dot products. the complexity of connecting four separate tubes together is eliminated. If additional capacity for more dot products is required. it is often more desirable to utilize four additional tubes, each of o-dot product capacity than four interconnected devices.

It may be desirable to alter a W, representation to a W new representation after the photochromic film has been altered represent W Wn. The arrangement shown in FIG. 4 permits this to be done by altering either the positive or'the negative photochromic film region alloted to W depending on whether Wnewis smaller or larger than W This alteration may be expressed in terms of Xi as, Wnea=Wizk Xi, where k is some constant.

After a dot product is obtained. the photochromic film must be bleached to decrease the opacity of all spots and ready it for the taking of other dot products. Reduction of capacity can be accomplished by heating the film. Heating coils or other means can be used to accomplish this. The opacity of every spot decreases in the manner described by the equation o==Am%' where represents light transmission, represents absolute temperature, A is a constant, K is Boltzrnan's Constant and E is an energy level characteristic of the material.

While particular embodiments of the invention have been described, many variations may be employed and the invention is limited only by a just interpretation of the following claims.

I claim:

1. Apparatus for performing mathematical manipulations comprising:

photochromic film means for providing numerous areas of variable opacity; opacity varying means for fixing the opacity of said areas in accordance with values of a first mathematical component;

light means for projecting light onto said film in accordance with second mathematical components of at least one value; and

photocell means disposed adjacent said film means for receiving light projecting through said film and for yielding an output substantially proportionate to the sum of the light incident on the photocell means.

2. Apparatus as defined in claim I wherein said opacity varying means and said light means comprise a cathode-ray tube having a face disposed in adjacent to said film means.

3. Apparatus as defined in claim 1 including:

polarity differentiating means for separating first electrical signals representing said first mathematical components having a first polarity from second electrical signals representing said first mathematical components having an opposite polarity; wherein said opacity varying means includes first means for varying the opacity of a first group of said areas of said photochromic film means in accordance with said second electrical signals;

said photocell means includes first cell means disposed adjacent said first group of said areas of said film means and second cell means disposed adjacent said second group of said areas of said film means; and further including circuitry including difference yielding means, said circuitry connected to said first and second cell means for providing signals representing the difference between the output of at least a portion of said first cell means and at least a portion of said second cell means, whereby to enable the obtaining of dot products where some of the components of at least one vector are negative. 4. A method for obtaining the dot product of a first and second vector comprising:

varying the opacity of area bits of an area in accordance with the value of components of said first vector;

projecting light against said area bits and maintaining the amount of light in each area bit in accordance with the value of components of said second vector; and

detecting the total amount of light passed through all of said area bits, whereby to obtain the sum of the products of corresponding components of said vectors.

5. A method as defined in claim 4 wherein the step of varying the opacity of area bits includes the shining of a narrow beam of light against material which undergoes a change in opacity in each area in accordance with the integral of light incident on the area, and varying the intensity of said light in accordance with the value of said components.

6. A method as defined in claim 4 wherein:

the variation of opacity insaid area bits is the same for components of zero magnitude as for any components of negative polarity and including; varying the opacity of area bits of a second area in accordance with the values of components of said first vector, the variation for components of positive polarity being the same as for components of zero magnitude;

projecting light against said area bits of said second area and maintaining the amount of light in each of said bits in accordance with the value of components of said second vector;

detecting the total amount of light passed through all of said area bits of said second area; and

obtaining an indication of the difference between the light passed through at least a portion of said first area and the light passed through at least a portion of said second area.

7. Apparatus for obtaining the dot products of vectors comprising:

a cathode-ray tube;

photochromic film means disposed on the face of said tube;

a first and second photocell disposed on a side of said film means opposite said tube face;

polarity detecting means for projecting light representing vector components of a first polarity against the area covered by said first photocell, and for projecting light representing vector components of a second polarity against the area covered by said second photocell;

means for obtaining the output of said second cell; and

difference amplifier means for indicating the difference between the outputs of said first and second photocells.

8. Apparatus for obtaining the dot products of vectors comprising a cathode-ray tube, photochromic film means disposed on the face of said tube, first, second, third, and fourth photocells disposed on a side of said film opposite said tube face;

first polarity detecting means for projecting light representing components of a first polarity of a first vector against the area covered by said first photocell and said second photocell, and for projecting light representing components of a second polarity of said first vector against the area covered by said third photocell and said fourth photocell;

second polarity detecting means for projecting light representing components of a first polarity of a second vector against the area covered by said first photocell and said third photocell, and for projecting light representing components of a second polarity of said second vector against the area covered by said second photocell and said fourth photocell;

second, third, and fourth means for obtaining the outputs of said second, third, and fourth photocells, respectively; and

means for indicating the difference between the sum of the outputs of said first and fourth photocells and the sum of the outputs of said second and third photocells.

9 A method for obtaining the dot product of two vectors comprising;

varying the resistance to passage of signals, of individual portions of a signal blocking means in accordance with the value of components of said first vector;

passing signals through said portions of said blocking means, of a signal strength before passage dependent upon the components of said second vector, the signals representing each component of said second vector passing through portions of said blocking means varied in accordance with corresponding components of said first vector; and

detecting an algebraic sum of all the signals passed through all of said portions of said blocking means. 

